package com.erp.gather.mapper;

import com.erp.gather.domain.vo.ErpSellerStoreCommodityRankStatisticsVo;
import com.ruoyi.common.core.mapper.BaseMapperPlus;
import com.ruoyi.gather.api.domain.ErpSellerStoreCommodityRankStatistics;
import com.ruoyi.gather.api.domain.dto.EvaluationProductDto;
import com.ruoyi.gather.api.domain.dto.ProductInfoModuleDto;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 店铺商品排行记录Mapper接口
 *
 * @author erp
 * @date 2024-01-03
 */
public interface ErpSellerStoreCommodityRankStatisticsMapper extends BaseMapperPlus<ErpSellerStoreCommodityRankStatisticsMapper, ErpSellerStoreCommodityRankStatistics, ErpSellerStoreCommodityRankStatisticsVo> {

    /**
     * 查询周期内的访客量
     * @param aeProductId
     * @param statisticalPeriod
     * @return
     */
    Integer selectVisitorsTotalsByTime(@Param("aeProductId") Long aeProductId,@Param("statisticalPeriod") Integer statisticalPeriod);

    List<ProductInfoModuleDto> getProductRankByStoreId(@Param("outOrder") String outOrder, @Param("productSource") Integer productSource, @Param("storeId") Long storeId, @Param("limit") Integer limit);

    List<Long> getProductsRankByPrimary(@Param("productId") Long productId,@Param("tem") String tem,
                                        @Param("productOut") Integer productOut,@Param("productSource")Integer productSource);

    List<EvaluationProductDto> getEvaluationProduct(@Param("storeIdList") List<Long> storeIdList, @Param("ids") List<String> shieldProductIds
            ,@Param("maxBig") String maxBig,@Param("minBig") String minBig);

    Integer isOutOrder(@Param("productId") Long productId);
}
